export interface Option {
    accessKeyID: string;
    accessKeySecret: string;
    securityToken?: string;
    bucket: string;
    endpoint: string;
}

export interface PutObjectOptions {
    headers?: object | undefined;
}

export interface PutObjectResult {
    name: string;
    url: string;
    data: object;
    res: NormalSuccessResponse;
}

export interface NormalSuccessResponse {
    status: number;
    size: number;
    rt: number;
}

export interface GetObjectResult {
    res: NormalSuccessResponse;
}

export interface RemoteStorage {
    stat(objectKey: string): Promise<boolean>;

    put(objectKey: string, filePath: string, options?: PutObjectOptions): Promise<PutObjectResult>;

    get(objectKey: string, filePath: string): Promise<GetObjectResult>;
}